package com.bailan.foreat.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

/**
 * <p>
 *
 * </p>
 *
 * @author ste
 * @since 2023-02-21 07:50:44
 */
@Data
@TableName("t_user")
public class User {

    public User() {

    }

    public User(String username, String password, String email, String tel, String userImg) {
        this.username = username;
        this.password = password;
        this.email = email;
        this.tel = tel;
        this.userImg = userImg;
    }

    public User(String username, String password, String email, String tel, Integer userPoints) {
        this.username = username;
        this.password = password;
        this.email = email;
        this.tel = tel;
        this.userPoints = userPoints;
    }

    /**
     * 用户id
     */
    @TableId("id")
    private Integer id;

    /**
     * 用户账号
     */
    @TableField("username")
    private String username;

    /**
     * 用户密码
     */
    @TableField("password")
    private String password;

    /**
     * 邮箱
     */
    @TableField("email")
    private String email;

    /**
     * 电话
     */
    @TableField("tel")
    private String tel;

    /**
     * 积分(订单status变为4进行自增，积分=消费*10)
     */
    @TableField("user_points")
    private Integer userPoints;

    /**
     * 用户头像图片
     */
    @TableField("user_img")
    private String userImg;


}
